Repository navigation
feat(agno): upgrade to v3.1.10 and add conversation compaction, HyDE and multi-turn eval examples - #91
Open
martimfasantos wants to merge 4 commits into
Open
feat(agno): upgrade to v3.1.10 and add conversation compaction, HyDE and multi-turn eval examples#91martimfasantos wants to merge 4 commits into
martimfasantos wants to merge 4 commits into
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
This PR upgrades Agno from
3.0.9to3.1.10and adds examples for the two headline 3.1.2 features, conversation compaction with a searchable archive and HyDE query transformation onKnowledge, plus multi-turn evals built on the evalCaserun arguments from 3.1.6.What changed
Package upgrade
agnoupgraded from3.0.9→3.1.10;pyproject.tomlfloor raised from>=2.8.2to>=3.1.10New examples added
22_conversation_compaction.pyCompaction(...)+agent.compact()folds a 25-row inventory into a 150-token summary, then the agent recovers one row through thesearch_compacted_historytool23_hyde_query_transform.pyKnowledge(query_transformer=HyDE(...))vs plain search over the same LanceDb table — HyDE ranks the answering page first, plain search ranks a word-overlap page first24_multi_turn_eval.pyCaserun arguments (session_id,user_id,session_state) — two cases share asession_idand run as turns of one conversation, so turn 2 books the slot from turn-1 history and session state; a third case takes aMessageinput in a fresh session. Suite passes 3/3Key changes in v3.0.9 → v3.1.10
Caserun arguments (3.1.6) —session_id,user_id,session_state,dependencies,metadataandknowledge_filters, withstr | Messageinput; cases sharing a session run as turns. Offloadedread_resultalso gainsmax_chars.Agent(compaction=True | Compaction(...)),agent.compact(), archived originals searchable viasearch_compacted_history.followups: bool | FollowupConfig); each@approvaltool call now gets its own approval record.MMRReranker/RecencyReranker(3.0.11);reranker=on vector DBs is deprecated. Alsocancellation_stageon run outputs andOpenAIResponses(use_previous_response_id=...).agno_fstable changed; old tables raiseSchemaOutdatedError.Agent(filesystem=...)and AgentOS role-based access control are new.CodingTools.run_shellis opt-in (3.0.10) viaenable_run_shell=True.ClaudeAgent/CodexAgentgainoutput_schema, retries and metrics (3.1.3) and run sandboxed (3.1.4–3.1.5);CodexAgentsigns in automatically withOPENAI_API_KEY(3.1.10).ChartToolsandKeenableTools, and workflow step files now reach the next step (3.1.4–3.1.5).Claude()defaults toclaude-sonnet-5-5and a newPostgresCheckpointStore(3.1.8); human-in-the-loop fix for union-typed user-input parameters (3.1.9).Notes
llms.txtnor guessed URLs have one, so22links the v3.1.2 cookbook file it mirrors.search_compacted_messages, notsearchable. The release notes use the wrong name; the example uses the real kwarg.OpenAIResponses(id="gpt-5.4"), not the caller's model. The release notes imply otherwise, so23passes the settings model explicitly.22logs two "tokenizers / tiktoken not installed" warnings. Without the optionalagno[tokenizers]extra, Agno estimates tokens from character counts; nothing fails, so the extra wasn't added. TheOUTPUTS.mdnote explains it.18_filesystem.pyis unaffected by the 3.1.0 table change because it deletes its database on start.24gets a new session id on every run. ACasewithoutsession_idruns in a generated session, so that line inOUTPUTS.mdwon't match a fresh run.21_tool_result_offloading.pyprints a shortersearch_resulton 3.1.10. The final answer is still correct, so itsOUTPUTS.mdsection is left as captured.Configuration
gpt-4o-mini) viasettings.pyagno>=3.1.10,lancedb,pydantic-settingsuvpackage managerTesting
All 25 examples ran with exit code 0 against v3.1.10.
OUTPUTS.mdupdated for the three new files (22,23,24) plus the header; the other 22 sections are unchanged.uv lock --check,uv sync --frozenandpy_compilepass locally.